package com.gang.music.core.interfaces;

import com.gang.music.core.shiro.ShiroUser;
import com.gang.music.system.entity.User;
import org.apache.shiro.authc.SimpleAuthenticationInfo;

import java.util.List;

/**
 * 定义shirorealm所需数据的接口
 *
 */
public interface ShiroService {
	
	User user(String userName);

	ShiroUser shiroUser(User user);
	
	List<String> findRolesByUserId(Long userId);

	List<String> findPermissionsByUserId(Long userId);

	SimpleAuthenticationInfo info(ShiroUser shiroUser, User user, String realmName);
}
